-
-
Notifications
You must be signed in to change notification settings - Fork 414
Android: Add proguard-common.txt #5809
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
mvn"androidx.emoji2:emoji2:1.5.0", | ||
mvn"androidx.emoji2:emoji2-views:1.5.0", | ||
mvn"androidx.emoji2:emoji2-bundled:1.5.0", | ||
mvn"androidx.window:window:1.4.0", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should be able to completely remove this (window extensions)
androidReleaseSettings() | ||
} | ||
|
||
def androidR8ExtraRules: T[Seq[String]] = Task { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Guessing this is a leftover
I'm suspecting the test apk must have a don't warn flag or even no minification or shrinking, but if this solves all the main apk packaging tasks to not need the error warn mapping, is a nice win |
|
||
// Common Proguard Rules used by AGP | ||
// Source: https://android.googlesource.com/platform/tools/base/+/refs/heads/studio-master-dev/build-system/gradle-core/src/main/resources/com/android/build/gradle/proguard-common.txt | ||
def commonProguardFile: T[PathRef] = Task { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
def commonProguardFile: T[PathRef] = Task { | |
def androidCommonProguardFile: T[PathRef] = Task { |
ad5f161
to
72c2ad9
Compare
…gs + cleanup compose examples
72c2ad9
to
9b840be
Compare
I have resolved the remaining issues and cleaned up some dependencies from the thirdparty compose samples, which I've also tested, probably androidtodo can be cleaned up from unnecessary dependencies too |
this PR resolves 2 issues:
Now the gradle and mill configurations look quite close to each other @souvlakias when you get the chance, could you update the PR description please (+with the above) and mark the PR as ready when it passes on our copy |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me.
it seems that this PR also fixes the slowness in androidtodo, there's 4 consecutive runs without a timeout, I'll keep an eye. but there were unneeded extra dependencies, which should make the example faster anyway |
heh, spoken too soon |
This PR resolves 2 issues:
The need to add extra dependencies due to the R8 detecting internal android classes as missing (Ref)
The need to pass
--map-diagnostics error warn
to r8 for the same reason.Now the gradle and mill configurations look quite close to each other
Motivation
In the thirdparty compose examples, classes such as
androidx.windows.sidecar.**
andandroidx.windows.extensions.**
are provided in runtime and R8 should not warn about them.We found that AGP seems to append this common rules file in order to avoid such warnings.
Changes
Added this file in
androidlib
's resources and always pass it to R8.